#pragma once
#include "nnse_support.h"

namespace SimpleGUI
{
	template <class T, class U> public ref class Layer : public System::Windows::Forms::Form
	{
		// Constructor and Destructor
			public: Layer(nnse::layer<T, U>^ p);
			protected: virtual ~Layer();
		// Member Variables
			private: System::ComponentModel::Container^ components;
			private: System::Windows::Forms::Label^  number_label;
			private: System::Windows::Forms::TextBox^  number_textBox;
			private: System::Windows::Forms::Label^  number_of_neurons_label;
			private: System::Windows::Forms::TextBox^  number_of_neurons_textBox;
			private: System::Windows::Forms::Button^  view_button;
			private: nnse::layer<T, U>^ parent;
		// GUI Functions
			private: System::Void view_button_Click(System::Object^  sender, System::EventArgs^  e);
			private: System::Void form_closed(System::Object^  sender, System::Windows::Forms::FormClosedEventArgs^  e);
			public: System::Void update_form();
#pragma region Windows Form Designer generated code
		/// <summary>
		/// Required method for Designer support - do not modify
		/// the contents of this method with the code editor.
		/// </summary>
		void InitializeComponent(void)
		{
			this->number_label = (gcnew System::Windows::Forms::Label());
			this->number_of_neurons_label = (gcnew System::Windows::Forms::Label());
			this->number_textBox = (gcnew System::Windows::Forms::TextBox());
			this->number_of_neurons_textBox = (gcnew System::Windows::Forms::TextBox());
			this->view_button = (gcnew System::Windows::Forms::Button());
			this->SuspendLayout();
			// 
			// number_label
			// 
			this->number_label->AutoSize = true;
			this->number_label->Location = System::Drawing::Point(12, 9);
			this->number_label->Name = L"number_label";
			this->number_label->Size = System::Drawing::Size(47, 13);
			this->number_label->TabIndex = 0;
			this->number_label->Text = L"Number:";
			// 
			// number_of_neurons_label
			// 
			this->number_of_neurons_label->AutoSize = true;
			this->number_of_neurons_label->Location = System::Drawing::Point(12, 35);
			this->number_of_neurons_label->Name = L"number_of_neurons_label";
			this->number_of_neurons_label->Size = System::Drawing::Size(102, 13);
			this->number_of_neurons_label->TabIndex = 1;
			this->number_of_neurons_label->Text = L"Number of Neurons:";
			// 
			// number_textBox
			// 
			this->number_textBox->Location = System::Drawing::Point(120, 6);
			this->number_textBox->Name = L"number_textBox";
			this->number_textBox->Size = System::Drawing::Size(100, 20);
			this->number_textBox->TabIndex = 2;
			// 
			// number_of_neurons_textBox
			// 
			this->number_of_neurons_textBox->Location = System::Drawing::Point(120, 32);
			this->number_of_neurons_textBox->Name = L"number_of_neurons_textBox";
			this->number_of_neurons_textBox->Size = System::Drawing::Size(100, 20);
			this->number_of_neurons_textBox->TabIndex = 3;
			// 
			// view_button
			// 
			this->view_button->Location = System::Drawing::Point(15, 64);
			this->view_button->Name = L"view_button";
			this->view_button->Size = System::Drawing::Size(205, 23);
			this->view_button->TabIndex = 4;
			this->view_button->Text = L"View Neurons in this Layer";
			this->view_button->UseVisualStyleBackColor = true;
			this->view_button->Click += gcnew System::EventHandler(this, &Layer::view_button_Click);
			// 
			// Layer
			// 
			this->AutoScaleDimensions = System::Drawing::SizeF(6, 13);
			this->AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
			this->ClientSize = System::Drawing::Size(235, 95);
			this->Controls->Add(this->view_button);
			this->Controls->Add(this->number_of_neurons_textBox);
			this->Controls->Add(this->number_textBox);
			this->Controls->Add(this->number_of_neurons_label);
			this->Controls->Add(this->number_label);
			this->Name = L"Layer";
			this->Text = L"Layer";
			this->FormClosed += gcnew System::Windows::Forms::FormClosedEventHandler(this, &Layer::form_closed);
			this->ResumeLayout(false);
			this->PerformLayout();

		}
#pragma endregion
	};
}
